using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Resources;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace KPIS.GERP.Models.ICM
{
	[DataContract, Table("IcmBidderQuotation")]
    public class BidderQuotation
    {

        public BidderQuotation()
        {
        }
    

		[Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
		[DataMember, Display(Name = "BidderQuoId", ResourceType = typeof(Resources.BidderQuotationResource))]
        public int BidderQuoId { get; set; }

		[ForeignKey("Bidder")]
		[DataMember, Display(Name = "BidderId", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<int> BidderId { get; set; }

        [ForeignKey("PurchaseRequestItem")]
		[DataMember, Display(Name = "PrItemId", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<int> PrItemId { get; set; }

		[DataMember, Display(Name = "ItemDescr", ResourceType = typeof(Resources.BidderQuotationResource))]
        public string Descr { get; set; }

		[DataMember, Display(Name = "ItemQty", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<int> Qty { get; set; }

		[DataMember, Display(Name = "ItemPrice", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> Price { get; set; }

		[DataMember, Display(Name = "ExcludeVatAmount", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> ExcludeVatAmount { get; set; }

		[DataMember, Display(Name = "VatAmount", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> VatAmount { get; set; }

		[DataMember, Display(Name = "DiscountPercent", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> DiscountPercent { get; set; }

		[DataMember, Display(Name = "ExtraDiscount", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> ExtraDiscount { get; set; }

		[DataMember, Display(Name = "NetAmount", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<decimal> NetAmount { get; set; }

		[DataMember, Display(Name = "Remarks", ResourceType = typeof(Resources.BidderQuotationResource))]
        public string Remarks { get; set; }

		[DataMember, Display(Name = "Selected", ResourceType = typeof(Resources.BidderQuotationResource))]
        public string Selected { get; set; }

		[DataMember, Display(Name = "SelectedReason", ResourceType = typeof(Resources.BidderQuotationResource))]
        public string SelectedReason { get; set; }

		[DataMember, Display(Name = "CreatedBy", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<int> CreatedBy { get; set; }

		[DataMember, Display(Name = "CreatedWhen", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<System.DateTime> CreatedWhen { get; set; }

		[DataMember, Display(Name = "UpdatedBy", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<int> UpdatedBy { get; set; }

		[DataMember, Display(Name = "UpdatedWhen", ResourceType = typeof(Resources.BidderQuotationResource))]
        public Nullable<System.DateTime> UpdatedWhen { get; set; }
 
        [DataMember]
		public virtual Bidder Bidder { get; set; }

        [DataMember]
        public virtual PurchaseRequestItem PurchaseRequestItem { get; set; }

        [DataMember, NotMapped]
        public virtual int? RemainQty { get; set; }

        [DataMember, NotMapped]
        public virtual decimal? RemainAmount { get; set; }
    }
}